package com.neusoft.sm.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.neusoft.sm.mapper.EmpMapper;
import com.neusoft.sm.po.Emp;
import com.neusoft.sm.service.EmpService;

@Service("empService")
public class EmpServiceImpl implements EmpService {

	@Autowired
	private EmpMapper empMapper;
	
	@Override
	public List<Emp> getListEmp() {
		return empMapper.getListEmp();
	}

	@Override
	public Emp getEmpById(int empno) {
		return empMapper.getEmpById(empno);
	}

	@Transactional
	public int tranfer() {
		empMapper.addrenyingying(7369);
		empMapper.minusrenwoxing(7566);
		return 1;
	}

}
